#include <stdio.h>
#include<stdlib.h>
#include<windows.h>
int main()
{
	int  i, j, c = 1, d = 1;
	int x = 1;
	int y = 5;
	int left = 0, right = 20, top = 0, bottom = 10;
	while (1)
	{
		x = x + c;
		y = y + d;
		system("cls");
		for (i = 0; i < x; i++)
			printf("\n");
		for (j = 0; j < y; j++)
			printf(" ");
		printf("o");
		if ((x == top) || (x == bottom));
		{
		c = -c;
		printf("\a");
	}
		if ((y == right) || (y == left))
		{
			d = -d;
			printf("\a");
		}
		Sleep(100);
	}
	system("pause");
	return 0;
}